<template>
  <div>
    <ul>
      <li v-for="(item, index) in items" :key="index">{{ item.message }}</li>
    </ul>
    <button @click="addItem">添加一条数据</button>
  </div>
</template>

<script>
export default {
  data() {
    return {
      items: [
        {message: 'Foo'},
        {message: 'Bar'},
      ]
    }
  },
  methods: {
    addItem () {
      const date = new Date()
      this.items.push(
        {message: date}
      )
    }
  }
 }
</script>

<style lang="less" scoped>
</style>